<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
    <link rel="stylesheet" href="../bootstrap/css/bootstrap.css">
    <style>
        body {
            margin:0;
            padding:0;
            font-family:sans-serif;
            background:#2C2255;
            background:url(../image/水漫漫.jpg);
            background-repeat: no-repeat;
            background-size:100%;
            font-size: 20px;
            font-family:STXingkai;
            color: #59ec0a;
        }
        a{
            text-decoration:none;
        }
        button{
            margin:10px;
        }

        td{
            width:200px;
            height:80px;
        }
    </style>
</head>
<body>
    <h1>售货单管理页面</h1>
    <div class="container" >
        <div class="row">
            <div class="span6">
                <ul class="breadcrumb">
                    <li>
                        <a href="#" onclick="identificationSalesman()">订单管理</a> <span class="divider">></span>
                    </li>
                    <li>
                        <a href="#" onclick="identifyFinancialOfficer()">订单管理</a> <span class="divider">></span>
                    </li>
                </ul>
            </div>
        </div>
    </div>

    <!--引入js文件-->
    <script type="text/javascript" src="../css/jquery-3.4.1.js"></script>
    <script src="../bootstrap/js/bootstrap.js" ></script>
    <script src="../vue/vue.js" charset="utf-8"></script>
    <script type="text/javascript" src="../css/my.js"></script>
    <script>
        //点击订单管理鉴别登录用户是否拥有业务员权限
        identificationSalesman=function () {
            $.ajax({
                type: "post",
                url: "../OrderForm/identificationSalesman",
                data: "",
                dataType: "json",
                success: function (data) {
                    if (data.message=="成功"){
                        window.location.href="OrderForm_list.html";
                    }else{
                        alert("你未拥有业务员权限，无法管理订单");
                    }
                }
            });
        }
        //点击审核订单鉴别登录用户是否拥有财务员权限
        identifyFinancialOfficer=function () {
            $.ajax({
                type: "post",
                url: "../OrderForm/identifyFinancialOfficer",
                data: "",
                dataType: "json",
                success: function (data) {
                    // 删除完成后重新查询第一页
                    if (data.message=="成功"){
                        window.location.href="treasurerOrderForm.html";
                    }else{
                        alert("你未拥有财务员权限，无法审核订单");
                    }
                }
            });
        }
    </script>
</body>
</html>